using System;
using System.Collections.Generic;
using System.Text;

using KLATencor.Infrastructure.StateModel;

namespace StateMachine_Graphical_Editor
{
    //used for instanciating a stateMachine class
    class IStateMachineHostImpl : IStateMachineHost
    {
        //private MTCLifecycleStateMachine _sm = null;
        private static IStateMachineHostImpl _host = new IStateMachineHostImpl();

        public ExceptionResponse OnExceptionCaught(ActionType actionType, System.Exception exception, string stateName)
        {
            //throw exception; 
            return ExceptionResponse.Ignore;
        }

        public void ValidateStateModel()
        {
        }

        public static IStateMachineHostImpl GetMTCStateMachineHost()
        {
            return _host;
        }
        
        //private MTCStateMachineHost()
        //{
        //    _sm = new MTCLifecycleStateMachine(this);
        //}

        //public void Start()
        //{
        //    _sm = new MTCLifecycleStateMachine(this);
        //    _sm.Start();
        //}

        //public void ShutDown()
        //{
        //    _sm.ShutDownMtcStateMachine();
        //    _sm = null;
        //}

        //public MTCLifecycleStateMachine MTCLifecycleStateMachine
        //{
        //    get { return _sm; }
        //}
    }
}
